package com.yunji.product.service;

import com.yunji.common.model.cache.ProductAgentCacheDTO;
import com.yunji.product.bo.ProductAgentListQueryBO;
import com.yunji.product.bo.ProductAgentSelectQueryBO;
import com.yunji.product.bo.ProductAgentUpdateBO;
import com.yunji.product.domain.ProductAgentDO;
import com.yunji.product.dto.ProductAgentPriceDTO;

import java.util.List;

/**
 * @Project: yunji-coffee
 * @Package com.yunji.product.service
 * @FileName IProductAgentService.java
 * @Copyright Copyright © 2024 云集互联. All Rights Reserved
 * @Company com
 * @Version 1.0
 * @Since JDK1.8.0_201
 * @CreateTime 2024-04-01 23:38:08
 * @Description 商品授权代理接口
 * @Modification History
 * Author					History Time			Version			Description
 * -------------------------------------------------------------------------------
 * HuaAo				2024-04-01 23:38:08		1.0				1.0
 */
public interface IProductAgentService {
    /**
     * @param agent 代理商品绑定关系
     * @Title create
     * @Desc 创建代理商品绑定关系
     * @Date 2024-06-11 16:55:40.593
     * @Return boolean 创建结果
     */
    boolean create(ProductAgentDO agent);

    /**
     * @param agent 代理商品绑定关系
     * @Title update
     * @Desc 更新代理商品绑定关系
     * @Date 2024-06-11 17:43:49.704
     * @Return boolean 更新结果
     */
    boolean update(ProductAgentDO agent);

    boolean updateByBO(ProductAgentUpdateBO bo);

    /**
     * @param agent 商品信息
     * @Title select
     * @Desc 获取当前代理商品信息详情
     * @Date 2024-06-11 17:59:59.891
     * @Return ProductAgent 商品信息详情
     */
    ProductAgentDO select(ProductAgentSelectQueryBO bo);

    /**
     * @param agent 代理商品过滤信息
     * @Title search
     * @Desc 查询商品代理信息列表
     * @Date 2024-06-11 18:01:54.802
     * @Return List<ProductAgent> 商品代理信息列表
     */
    List<ProductAgentDO> search(ProductAgentListQueryBO bo);

    List<ProductAgentPriceDTO> searchDTO(ProductAgentListQueryBO agent);

    List<Long> selectAgentIdByProductId(Long... ids);

    boolean deleteByManagerIds(Long... managerId);

    boolean deleteByProductId(Long[] ids);

    ProductAgentCacheDTO getCacheByBelong(Long belongId, Long productId);

    List<ProductAgentCacheDTO> getCacheByBelong(Long belongId, List<Long> productIds);
}
